package main

import (
	"fmt"

	"github.com/spf13/cobra"
)

func main() {
	//Execute the simple command sample
	simpleRun()
}

func simpleRun() {
	var rootCmd = &cobra.Command{
		Use:   "run",
		Short: "run the application",
		Run: func(cmd *cobra.Command, args []string) {
			fmt.Println("run the application")
		},
	}

	var serverCmd = &cobra.Command{
		Use:   "server",
		Short: "Run the server",
	}

	var startCmd = &cobra.Command{
		Use:   "start",
		Short: "start process",
		Run: func(cmd *cobra.Command, args []string) {
			fmt.Println("start process")
		},
	}
	serverCmd.AddCommand(startCmd)
	rootCmd.AddCommand(serverCmd)
	rootCmd.Execute()
}
